def insert_sort(sort_list):
    for index in range(1, len(sort_list)):

        current_value = sort_list[index]
        position = index

        while position > 0 and sort_list[position-1] > current_value:
            sort_list[position] = sort_list[position - 1]
            position = position - 1

        sort_list[position] = current_value


if __name__ == '__main__':
    sort_list = [1, 222, 4, 45, 67, 25, 12]
    insert_sort(sort_list)
    print(sort_list)